#ifndef __BOIDS_H__
#define __BOIDS_H__

#include <GL/glut.h>

#define BOID_N_BODIES           2048
#define BOID_SPEED              0.0003
#define GHOUL_SPEED             0.0055
#define GHOUL_ACCELERATION      0.8
#define HUNGER_SCATTER_LIMIT    100
#define HUNGER_EAT_LIMIT        (HUNGER_SCATTER_LIMIT / 2)
#define BOID_PROXIMITY_LIMIT    0.08
#define GHOUL_CANDIDATE_LIMIT   0.4
#define GHOUL_ATTACK_LIMIT      0.006
#define BOID_N_COLOR_PARAM      3
#define SPACE                   0.04

enum LookDirection {
	NORTH,
	EAST,
	SOUTH,
	WEST
};

enum DirSync {
	NO_SYNC,
	SYNC
};

enum BoidStatus {
	BOID_HUMAN,
	BOID_GHOUL
};

typedef struct {
	GLint 	 id;
	GLuint   quadrant;
	GLfloat  x;
	GLfloat  y;
	GLuint   status;
	GLint    nnID;
	GLfloat  nnDist;
	GLint    dirSync;
	GLuint   weight;
	GLuint   hunger;
	int      look;
	int      count;
	GLuint   neighborCount;
	GLfloat  rgb[BOID_N_COLOR_PARAM];
	GLint    neighbor[BOID_N_BODIES];
}boid_t;

void initBoids(void);
void drawAllBoids(void);
void makeBoidsUpdate(void);

#endif  /* __BOIDS_H__ */
